package com.owen.he.jee.vo.excel;

import java.io.Serializable;
import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.apache.poi.ss.formula.functions.T;

/**
 * 导入Excel处理返回的结果集封装
 * @author owen.he
 *
 */
public class ImportExcelResult implements Serializable{

	private static final long serialVersionUID = -6720948270440261318L;
	
	private List<T> errotResult;//需要校验的结果集
	private int successRecord = 0;//成功记录数
	private int failRecord = 0;//失败记录数
	private boolean recordIsOk = true;//单条处理是否OK，用户单条
	private Map<String,Object> mesageResult = new HashMap<>();//用户描述导入的结果，key必须为error
	
	public List<T> getErrotResult() {
		return errotResult;
	}
	public void setErrotResult(List<T> errotResult) {
		this.errotResult = errotResult;
	}
	public int getSuccessRecord() {
		return successRecord;
	}
	public void setSuccessRecord(int successRecord) {
		this.successRecord = successRecord;
	}
	public int getFailRecord() {
		return failRecord;
	}
	public void setFailRecord(int failRecord) {
		this.failRecord = failRecord;
	}
	public boolean isRecordIsOk() {
		return recordIsOk;
	}
	public void setRecordIsOk(boolean recordIsOk) {
		this.recordIsOk = recordIsOk;
	}
	
	public Map<String, Object> getMesageResult() {
		return mesageResult;
	}
	public void setMesageResult(Map<String, Object> mesageResult) {
		this.mesageResult = mesageResult;
	}
	
	@Override
	public String toString() {
		return "ImportExcelResult [successRecord=" + successRecord
				+ ", failRecord=" + failRecord + ", recordIsOk=" + recordIsOk
				+ ", mesageResult=" + mesageResult + "]";
	}
}
